package net.siufung.simple.demo.service;

import com.alibaba.fastjson.JSON;
import com.google.common.eventbus.Subscribe;
import lombok.extern.slf4j.Slf4j;
import net.siufung.core.event.IEventConsumer;
import net.siufung.simple.demo.Event1;
import org.springframework.stereotype.Component;

/**
 * @author 陈建峰
 * @date 2022/9/27 10:06 上午
 * @since V1.0.0
 */
@Component
@Slf4j
public class DemoRecordNotify implements IEventConsumer<Event1> {

    @Subscribe
    @Override
    public void consumer(Event1 event) {
        log.info("event:{}", JSON.toJSONString(event));
    }
}
